package com.sec.android.app.myfiles.util.securefolder;

import android.content.Context;
import android.os.Environment;
import android.util.Log;

public class SecureConstants {

    private static final String TAG = SecureConstants.class.getSimpleName();

    public static final String externalStoragePath = Environment.getExternalStorageDirectory().getPath();
    public static final String externalStorageAbsolutePath = Environment.getExternalStorageDirectory().getAbsolutePath();

    public static final String privateRecoveryRootPath = externalStoragePath + "/.PrivateRecovery";


    //Test files
    public static final String testFile1Path = externalStoragePath + "/Test/testfile1";
    public static final String testFile2Path = externalStoragePath + "/Test/testfile2";
    public static final String testVideo1Path = externalStoragePath + "/Test/test1.mp4";

    public static final String newFile1Path = privateRecoveryRootPath + "/.testfile1";
    public static final String newFile2Path = privateRecoveryRootPath + "/.testfile2";
    public static final String newVideo1Path = privateRecoveryRootPath + "/.video1.mp4";

    /*
    01-01 08:54:01.625 18853-18853/com.hyl.gpsdemo_default I/HideUtils: externalStoragePath: /storage/emulated/0
01-01 08:54:01.625 18853-18853/com.hyl.gpsdemo_default I/HideUtils: externalStorageAbsolutePath: /storage/emulated/0
01-01 08:54:01.625 18853-18853/com.hyl.gpsdemo_default I/HideUtils: context.getFilesDir(): /data/user/0/com.hyl.gpsdemo_default/files
01-01 08:54:01.625 18853-18853/com.hyl.gpsdemo_default I/HideUtils: context.getCacheDir(): /data/user/0/com.hyl.gpsdemo_default/cache
01-01 08:54:01.627 18853-18853/com.hyl.gpsdemo_default I/HideUtils: context.getExternalFilesDir(): /storage/emulated/0/Android/data/com.hyl.gpsdemo_default/files
01-01 08:54:01.630 18853-18853/com.hyl.gpsdemo_default I/HideUtils: context.getExternalCacheDir(): /storage/emulated/0/Android/data/com.hyl.gpsdemo_default/cache
     */

    public void testPrintPath(Context context) {
        //外置公共存储
        Log.i(TAG, "externalStoragePath: " + externalStoragePath);      //  /storage/emulated/0
        Log.i(TAG, "externalStorageAbsolutePath: " + externalStorageAbsolutePath);  // /storage/emulated/0

        //App内部私有存储
        Log.i(TAG, "context.getFilesDir(): " + context.getFilesDir());   ///data/user/0/com.hyl.gpsdemo_default/files  (好像也就是 /data/data/... ?)
        Log.i(TAG, "context.getCacheDir(): " + context.getCacheDir());  ///data/user/0/com.hyl.gpsdemo_default/cache (同上）

        //App外置扩展存储
        Log.i(TAG, "context.getExternalFilesDir(): " + context.getExternalFilesDir(null));   // /storage/emulated/0/Android/data/com.hyl.gpsdemo_default/files
        Log.i(TAG, "context.getExternalCacheDir(): " + context.getExternalCacheDir());       // /storage/emulated/0/Android/data/com.hyl.gpsdemo_default/cache
    }

}
